function getTime(start, end) {
  var parent = document.querySelector(".video-pod__body");
  var childList = parent.children;
  var nowMiaoTime = 0;
  if (start == undefined && end == undefined) {
    for (let i = 0; i < childList[0].children.length; i++) {
      var timeStrList = childList[0].children[i]
        .querySelector(".stat-item")
        .innerText.split(":");
      var MillTimeSum = timeStrList[0] * 60 + timeStrList[1] * 1;
      nowMiaoTime += MillTimeSum;
    }
    var time =
      Math.floor(nowMiaoTime / 3600) +
      "小时" +
      Math.floor((nowMiaoTime % 3600) / 60) +
      "分钟" +
      (nowMiaoTime % 60) +
      "秒";
    console.log(time);
  } else {
    for (let i = start - 1; i < end; i++) {
      var timeStrList = childList[0].children[i]
        .querySelector(".stat-item")
        .innerText.split(":");
      var MillTimeSum = timeStrList[0] * 60 + timeStrList[1] * 1;
      nowMiaoTime += MillTimeSum;
    }
    var time =
      Math.floor(nowMiaoTime / 3600) +
      "小时" +
      Math.floor((nowMiaoTime % 3600) / 60) +
      "分钟" +
      (nowMiaoTime % 60) +
      "秒";
    console.log(time);
  }
}

// (无参时)获取当前视频所有章节的总时长
getTime();
// ((有参数时)获取从第几个到第几个视频的总时长
getTime(1, 2);